import multiprocessing

a = 100


def add():
    global a
    a += 30
    print(a)


def sub():
    global a
    a -= 20
    print(a)


if __name__ == '__main__':
    print('a =', a)
    add_process = multiprocessing.Process(target=add)
    sub_process = multiprocessing.Process(target=sub)
    add_process.start()
    add_process.join()
    sub_process.start()
    sub_process.join()
    print('a =', a)
